/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package other;

import java.io.Serializable;

public class FileInfo implements Serializable,Comparable<FileInfo> {
	private static final long serialVersionUID = -3456456456451135225L;
	String name;
        String type;
        String size;
        String path;

        public FileInfo(){};
        public FileInfo(String name1,String type1,String size1,String path1){
        	name= name1; type= type1;
        	size= size1; path= path1;
        }
        
	public void setname(String a){name =a ;}
	public void settype(String a){type =a ;}
        public void setsize(String a){size =a ;}
	public void setpath(String a){path =a ;}
        public String getname(){return name;}
        public String gettype(){return type ;}
        public String getsize(){return size;}
        public String getpath(){return path ;}
        
        @Override

    public int compareTo(FileInfo o) {

        if(this.name != null) {
            return this.name.toLowerCase().compareTo(o.getname().toLowerCase());
        }

        else {
            throw new IllegalArgumentException();
        }

    }


}
